<template>
	<view>
		<u-popup
			v-model="show" 
			mode="bottom" 
			:mask-close-able="false" 
			border-radius="40"
			closeable
			close-icon-size="40"
		>
			<view class="popup-container">
				<view class="title">关注公众号后，领取优惠券</view>
				<official-account @load="loadSuc"></official-account>
			</view>
		</u-popup>
	</view>
</template>

<script> 
	
	export default {
		data() {
			return {
				show:false,
				canTap: false
			}
		},
		mounted() {
			setTimeout(() => {
				this.canTap = true;
			},1500)
		},
		methods:{
			open() {
				this.show = true;
			},
			close() {
				if(this.canTap) {
					this.show = false;
				};
			},
			loadSuc() {
				this.$emit('loadSuc');
			} 
		}
	}
</script>

<style lang="scss">
.popup-container {
	width: 100vw; 
	height: 420rpx;
	padding: 0 20rpx;
	.title {
		color: #333333;
		font-size: 30rpx;
		padding: 60rpx;
		text-align: center;
	}
}
</style>
